#if !defined(SM__CHARACTER_H)
#define SM__CHARACTER_H

#include "swagme.h"
#include "Sprite.h"

#define FRAMES_PER_ANIM 3


class Character {
  public:
    Character(Sprite* ps, int x, int y);
    void Init(Sprite* ps, int x, int y);
    Character(Sprite* ps);
    Character();
    ~Character();
    int Draw(int animSpeed, SDL_Surface *dst);
    int Blit(SDL_Surface *dst, int x, int y);
    void SetFacing(sm_direction f);
    sm_direction GetFacing();

    int posX;
    int posY; // current coords of player
    int prevX;
    int prevY; // last coords of player
    Sprite *mpSprite;
    static const int speed;

  private:
    sm_direction Facing;
    sm_direction prevFacing;
    char *SpriteImageFile; // image file to load sprite surface from
    static const int FrameCount;
    int FrameCounter;
};

#endif // SM__CHARACTER_H
